home *** CD-ROM | disk | FTP | other *** search
/ Columbia Kermit / kermit.zip / newsgroups / misc.19951130-19960209 / 000030_news@columbia.edu_Tue Dec 5 11:20:17 1995.msg < prev    next >
Internet Message Format  |  2020-01-01  |  5KB

  1. Received: from apakabar.cc.columbia.edu by watsun.cc.columbia.edu with SMTP id AA14129
  2.   (5.65c+CU/IDA-1.4.4/HLK for <kermit.misc@watsun>); Wed, 6 Dec 1995 02:37:23 -0500
  3. Received: (from news@localhost) by apakabar.cc.columbia.edu (8.6.12/8.6.12) id CAA17410 for kermit.misc@watsun; Wed, 6 Dec 1995 02:37:21 -0500
  4. Path: news.columbia.edu!panix!bloom-beacon.mit.edu!gatech!newsfeed.internetmci.com!in2.uu.net!brighton.openmarket.com!decwrl!tribune.usask.ca!news.uregina.ca!MAX.CC.Uregina.CA!VOGTPATR
  5. From: VOGTPATR@MAX.CC.Uregina.CA (Warren Vogt)
  6. Newsgroups: comp.protocols.kermit.misc
  7. Subject: Local printing of Web-browser links. Here's how:
  8. Date: Tue, 05 Dec 95 17:20:17 CST
  9. Organization: University of Regina
  10. Lines: 79
  11. Message-Id: <1746BF3E7.VOGTPATR@MAX.CC.Uregina.CA>
  12. Nntp-Posting-Host: max.cc.uregina.ca
  13. Apparently-To: kermit.misc@watsun.cc.columbia.edu
  14.  
  15. My experiment with using VT200 codes to send a Web-browser's selected document
  16. to the PC's printer instead of to the screen has yielded the following results,
  17. including a solution of how to force VMS to send those codes when the applica-
  18. tion isn't set up to.
  19.  
  20. Kermit's echo and write screen don't work; they display to the local not the
  21. connect session.
  22. Assigning these codes to a key fails in or out of connect. Using the "output"
  23. statement also fails, because what is Output from Kermit is Input to the host!
  24. VMS "DEFINE /KEY" always fails. In fact it inexplicably cannot be made to do
  25. anything, even though VMS /LOG messages claim otherwise. To replicate its ef-
  26. fect, use Kermit's set key nnn output {VMS command} . And if I'm not mistaken,
  27. the \KudkFn is no help here because its effect is defined for the Kermit, not
  28. the host, prompt. It performs services to Kermit or DOS, not to VMS, I think.
  29.  
  30. No. In order for Kermit to respond to these codes, the host must OUTPUT them
  31. itself! But how do we make it happen? Not all host applications are aware of
  32. this option. VTWWW was one that is. It is gone now and Lynx remains. Fortun-
  33. ately I have taught it how to perform this trick. That is explained in the DCL
  34. program at the end of the letter.
  35.  
  36. If the application, refuses to emit CSI 5 i , CSI 4 i (the eight-bit forms of
  37. on/off), you can assign these values to symbols and have the host output them
  38. with WRITE SYS$OUTPUT symb or TYPE SYS$INPUT <stream> . The procedure at the
  39. end uses the first method. With set key output {WRITE etc.} \13 , it can be as-
  40. signed to a key as if DEC's DEFINE /KEY had done it.
  41.  
  42. By modifying an application's config. file, the procedure can be invoked from
  43. inside it. When that's not possible, do SPAWN WRITE SYS$OUTPUT symb . If it
  44. doesn't permit so short an interruption, you still have a recourse: Type your
  45. modem's escape series & type the codes manually. Here's how it's done with the
  46. seven-bit ones:
  47.      +++
  48.      OK              (says your modem)
  49.      Ctrl-[ [ 5 i    (no spaces. 5 starts 4 stops controlled printing)
  50.      AT O1           (go back to the host. Type commands without seeing them)
  51.  
  52. This method is unreliable. It can put junk in the way of the DCL commands you
  53. enter without your seeing. CLEAR the input buffer first. Then maybe...
  54.  
  55. Here is a procedure for Typing a VMS file and making it appear on your printer
  56. or on your micro's disk if Kermit's SET PRINTER was asked for. Some applica-
  57. tions will use it at your request. How is explained inside.
  58.  
  59. My thanks to John, Frank and Joe for supplementing the information in Christine
  60. Gianone's 1990 (first edition) book with more current advice.
  61.  
  62. ------------------------------------CUT HERE-----------------------------------
  63.  
  64. $ ! This program tells the LYNX Web-browser, VMS version, how to send a plain
  65. $ ! or formatted text file that it is referencing to the DEC VT's or PC's
  66. $ ! attached printer instead of to the screen. The VT200 "Printer controller"
  67. $ ! function is 99% transparent to all byte values, but it should not be used
  68. $ ! for binary (executable) files. Download them with Kermit's Send File , Type
  69. $ ! Binary function. -- Written by Warren Vogt on Dec. 4, 1995. Anyone may use.
  70. $ ! To avoid conflict with a program called "lpansi" that can do what this one
  71. $ ! does, this procedure has been given the name PANSY.COM and the following
  72. $ ! enabling line inserted into my copy of the LYNX.CFG file :
  73. $ ! PRINTER:To the printer of a DEC VT or a PC running Kermit:@PANSY %s :TRUE
  74. $ !
  75. $ SET SYMBOL /GENERAL /SCOPE=NOGLOBAL
  76. $ PRNON = "P[5i"
  77. $ PRNON[0,8] = %D27
  78. $ PRNOFF = "P[4i"
  79. $ PRNOFF[0,8] = %D27
  80. $ WRITE SYS$OUTPUT "The current link, if a text-file, will go to the PC's
  81. printer."
  82. $ INQUIRE DECIDE "Type Y <RET> if your printer or Kermit's SET PRINTER is ready"
  83. $ IF .NOT. DECIDE THEN $ EXIT
  84. $ WRITE SYS$OUTPUT "Printing begins..."
  85. $ WRITE SYS$OUTPUT F$STRING(PRNON)
  86. $ TYPE /NOPAGE 'P1
  87. $ WRITE SYS$OUTPUT F$STRING(PRNOFF)
  88. $ SUMMON = " The document has been printed!BBBB"
  89. $ SUMMON[248,16] = %O3407
  90. $ SUMMON[264,16] = %O3407
  91. $ WRITE SYS$OUTPUT F$STRING(SUMMON)
  92. $ ! WAIT 00:00:13 ! 13 seconds chosen because less is ignored, more is tedious.
  93. $ EXIT